---
page_title: "cloudflare_pages_domain Resource - Cloudflare"
subcategory: ""
description: |-
  Provides a resource for managing Cloudflare Pages domains.
---

# cloudflare_pages_domain (Resource)

Provides a resource for managing Cloudflare Pages domains.

-> A DNS record for the domain is not automatically created. You need to create
   a `cloudflare_record` resource for the domain you want to use.

## Example Usage

```terraform
resource "cloudflare_pages_domain" "my-domain" {
  account_id   = "f037e56e89293a057740de681ac9abbe"
  project_name = "my-example-project"
  domain       = "example.com"
}
```
<!-- schema generated by tfplugindocs -->
## Schema

### Required

- `account_id` (String) The account identifier to target for the resource. **Modifying this attribute will force creation of a new resource.**
- `domain` (String) Custom domain. **Modifying this attribute will force creation of a new resource.**
- `project_name` (String) Name of the Pages Project. **Modifying this attribute will force creation of a new resource.**

### Read-Only

- `id` (String) The ID of this resource.
- `status` (String) Status of the custom domain.

## Import

Import is supported using the following syntax:

```shell
$ terraform import cloudflare_pages_domain.example <account_id>/<project_name>/<domain-name>
```
